<!-- 类Picker弹窗 -->
<template>
	<u-popup v-model="showpoup" mode="bottom" @close="close" :length="length" border-radius="30">
		<view class="main">
			<view class="title">
				{{title}}
			</view>
			<view class="ul">
				<view class="li" v-for="(item,index) in list" :key="index" @click="choose(index)">
					{{item}}
				</view>
			</view>
		</view>
	</u-popup>
</template>

<script>
	export default {
		name: "Rpoup",
		props: ['showpoup', 'title', 'list', 'length'],
		data() {
			return {

			};
		},
		methods: {
			choose(index) {
				this.$emit('choose',index)
			},
			close(){
				this.$emit('close')
			},
		}
	}
</script>
<style lang="scss" scoped>
	text{
		display: block;
	}
	.main {
		position: relative;

		.title {
			border-bottom: 2rpx solid #eee;
			font-size: 36rpx;
			font-family: PingFang SC;
			font-weight: 500;
			color: #333333;
			height: 100rpx;
			line-height: 100rpx;
			text-align: center;
			position: fixed;
			background: #fff;
			width: 100%;
			z-index: 8;
		}

		.ul {
			width: 100%;
			position: absolute;
			top: 100rpx;
			height: 90%;

			.li {
				width: 100%;
				text-align: center;
				font-size: 30rpx;
				font-family: PingFang SC;
				font-weight: 500;
				color: #666666;
				line-height: 90rpx;
			}
		}
	}
</style>
